package final_;

/**
 * @Author 小闽
 * @Date 2024/9/10 19:32
 * @PackageName: final_
 * @ClassName: finalExercise01
 * @Description: final练习
 * @Version 1.0
 */
public class finalExercise01 {
    public static void main(String[] args) {
        Circle circle = new Circle(3.0);
        System.out.println(circle.circleArea());

    }
}

class Circle{
    private double radius;
    private final double PI;

    public Circle(double radius) {
        this.radius = radius;
    }
    {
        PI = 3.14;
    }

    public double circleArea(){
        return PI * radius * radius;
    }
}